package com.feng.boot.jdbc.controller;

import com.feng.boot.jdbc.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

/**
 * @author Lee
 */
@RestController
public class UserController {

    @Autowired
    private UserService userService;

    @GetMapping("/findUsers")
    public List<Map<String, Object>> findUsers(@RequestParam(value = "start") int start){
        int size = 10000;
        return userService.findAll(start,size);
    }

}
